const btn = document.querySelectorAll(".swiper-slide>.button");
const ula = document.querySelector(".ula");
ula.addEventListener("click", function (e) {
  const i = e.target.dataset.id;
  console.log(i);

  if (e.target.tagName === "BUTTON") {
    setTimeout(() => {
      btn[i].classList.add("active");
      switch (i) {
        case "0":
          window.location.href = "../magsafe.html";
          break;
        case "1":
          window.location.href = "#";
          break;
        case "2":
          window.location.href = "#";
          break;
        case "3":
          window.location.href = "#";
          break;
        case "4":
          window.location.href = "#";
          break;
        case "5":
          window.location.href = "#";
          break;
        case "6":
          window.location.href = "#";
          break;
      }
    }, 100);
  }
});
